package com.pickgliss.loader
{
	import com.pickgliss.loader.DataAnalyzer;
	
	import flash.utils.Dictionary;
	
	public class UiConfigAnalyzer extends DataAnalyzer
	{
		public function UiConfigAnalyzer(onCompleteCall:Function)
		{
			super(onCompleteCall);
		}
		private static var _data : Dictionary;
		public static function get data() : Dictionary
		{
			return _data;
		}
		override public function analyze(data:*):void
		{
			var xml : XML = new XML(data);
			_data = new Dictionary(true);
			var xlist : XMLList = xml..Item;
			for each(var obj : * in xlist)
			{
				_data[String(obj.@name)] = int(obj.@size);
			}
			onAnalyzeComplete();
		}
	}
}